import request from '@/config/axios'

// 教练信息 VO
export interface InstructorInfoVO {
  id: number // 编号
  name: string // 姓名
  description: string // 描述
}

// 教练信息 API
export const InstructorInfoApi = {
  // 查询教练信息分页
  getInstructorInfoPage: async (params: any) => {
    return await request.get({ url: `/booking/instructor-info/page`, params })
  },

  // 查询教练信息详情
  getInstructorInfo: async (id: number) => {
    return await request.get({ url: `/booking/instructor-info/get?id=` + id })
  },

  // 新增教练信息
  createInstructorInfo: async (data: InstructorInfoVO) => {
    return await request.post({ url: `/booking/instructor-info/create`, data })
  },

  // 修改教练信息
  updateInstructorInfo: async (data: InstructorInfoVO) => {
    return await request.put({ url: `/booking/instructor-info/update`, data })
  },

  // 删除教练信息
  deleteInstructorInfo: async (id: number) => {
    return await request.delete({ url: `/booking/instructor-info/delete?id=` + id })
  },

  // 导出教练信息 Excel
  exportInstructorInfo: async (params) => {
    return await request.download({ url: `/booking/instructor-info/export-excel`, params })
  }
}